package model;

import java.io.Serializable;

/********************************************************
 * Class: Item
 * @author jdsmith
 * created on 9/12/2012
 * 
 * description: Represents an item in an order placed
 * by a customer.
 */

public class Item implements Serializable {
	/**
	 * 
	 */
	private static final long serialVersionUID = 9208317200642839657L;
	private String partNum; //the item's unique identifier (4-digits)
	private String name; //25 characters or less
	private Integer quantity;
	
	/**
	 * constructor
	 * @param a part number id
	 * @param the item's name
	 * @param the quantity of items
	 */
	public Item(String partNum, String name, Integer quantity){
		//check lengths of partnum and name
		this.partNum = partNum;
		this.name = name;
		this.quantity = quantity;
	}

	/**
	 * getters and setters
	 */
	public String getPartNum() {
		return partNum;
	}

	public void setPartNum(String partNum) {
		this.partNum = partNum;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Integer getQuantity() {
		return quantity;
	}

	public void setQuantity(Integer quantity) {
		this.quantity = quantity;
	}
	
	
	
	

}
